#pragma once
#include <boost/tuple/tuple.hpp>
#include "../Engine/WeaponFwd.hpp"

namespace he
{
	//! Weapon manager.
	class WeaponManager : boost::noncopyable
	{
		// Typedefs
	private:
		//! Weapon tuple (files size, last modification date, weapon ptr).
		typedef boost::tuple<unsigned int, std::time_t, WeaponPtr_t> WeaponTuple_t;
		//! Map of weapons.
		typedef std::map<std::string, WeaponTuple_t> WeaponMap_t;

		// Attributes
	private:
		//! Working path.
		boost::filesystem::path const &m_WrkPath;
		
		// Operations
	public:
		//! Get the weapon (reload file if necessary).
		WeaponPtr_t get_weapon(std::string const &Name);

		// Construction/Destruction
	public:
		WeaponManager(boost::filesystem::path const &WrkPath);
	};
} /*he*/
